home *** CD-ROM | disk | FTP | other *** search
/ The Weather Channel - Everything Weather / TheWeatherChannel-EverythingWeather-Win31.iso / twcia / htracker / htracker.dxr / 00013_Start movie.ls < prev    next >
Encoding:
Text File  |  1995-08-22  |  3.0 KB  |  100 lines

  1. on startMovie
  2.   global stormNames, fileNames, bkHilite, fwdHilite, addHilite, editFlag, stormData1, stormPlot1, stormPlot2, currentLocation, nameHilite, nameHilite1, Xscale, Yscale, plotSprite, plotSprite2, hSprite, secondary, nameIndex, HDPath, CDPath
  3.   globalButtonInit(44, 48)
  4.   set editFlag to 0
  5.   set the visible of sprite 40 to 0
  6.   set Xscale to 602.0 / 80.0
  7.   set Yscale to 339.0 / 45.0
  8.   set nameHilite to 11
  9.   set nameHilite1 to 19
  10.   set the visible of sprite nameHilite to 0
  11.   set the visible of sprite nameHilite1 to 0
  12.   set bkHilite to 27
  13.   set the visible of sprite bkHilite to 0
  14.   set fwdHilite to 28
  15.   set the visible of sprite fwdHilite to 0
  16.   set addHilite to 29
  17.   set the visible of sprite addHilite to 0
  18.   set currentLocation to 1
  19.   set plotSprite2 to 16
  20.   set plotSprite to 17
  21.   set hSprite to 18
  22.   puppetSprite(16, 1)
  23.   puppetSprite(17, 1)
  24.   puppetSprite(18, 1)
  25.   set the locH of sprite plotSprite to -2000
  26.   set the locV of sprite plotSprite to -2000
  27.   set the locH of sprite hSprite to -2000
  28.   set the locV of sprite hSprite to -2000
  29.   set the trails of sprite plotSprite to 1
  30.   set the trails of sprite plotSprite2 to 1
  31.   set obj to FileIO(mnew, "read", HDPath & "htracker\DOSnames.txt")
  32.   set fileNames to obj(mReadFile)
  33.   obj(mdispose)
  34.   set obj to FileIO(mnew, "read", HDPath & "htracker\Stmnames.txt")
  35.   set stormNames to obj(mReadFile)
  36.   obj(mdispose)
  37.   set the text of field "storms" to stormNames
  38.   set stormData1 to the short date
  39.   set nameIndex to the number of lines in stormData1
  40.   set stormPlot1 to []
  41.   set stormPlot2 to []
  42.   set secondary to 0
  43.   set the text of field "stormName" to "no storm loaded"
  44.   set the text of field "name" to "no storm loaded"
  45.   set the text of field "name1" to "no secondary storm"
  46.   set the text of field "counter" to "1 of 1 "
  47.   set the text of field "date" to the date
  48.   set the text of field "time" to EMPTY
  49.   set the text of field "lat" to EMPTY
  50.   set the text of field "lon" to EMPTY
  51.   set the text of field "speed" to EMPTY
  52.   set the text of field "direction" to EMPTY
  53.   set the text of field "wind speed" to EMPTY
  54.   set the text of field "pressure" to EMPTY
  55.   set the keyDownScript to "keyScript"
  56.   set the mouseDownScript to "click"
  57. end
  58.  
  59. on click
  60.   if the clickOn then
  61.     puppetSound("click1.aif")
  62.     updateStage()
  63.   end if
  64. end
  65.  
  66. on stopMovie
  67.   set the keyDownScript to EMPTY
  68. end
  69.  
  70. on keyScript
  71.   global editFlag
  72.   if the key = RETURN then
  73.     set the selStart to 0
  74.     set the selEnd to 0
  75.     dontPassEvent()
  76.   else
  77.     set editFlag to 1
  78.   end if
  79. end
  80.  
  81. on printScreen
  82.   global CDPath
  83.   if objectp(printer) then
  84.     printer(mdispose)
  85.   else
  86.     openXLib(CDPath & "mainmenu\pmatic.dll")
  87.   end if
  88.   set printer to PrintOMatic(mnew)
  89.   printer(mRegister, "10056779-130")
  90.   printer(mSetLandscapeMode, 1)
  91.   printer(mReset)
  92.   printer(mNewPage)
  93.   printer(mStagePicture, 30, 0, printer(mGetPageWidth), printer(mGetPageHeight))
  94.   printer(mPrint)
  95.   printer(mReset)
  96.   printer(mSetLandscapeMode, 0)
  97.   printer(mdispose)
  98.   closeXLib(CDPath & "mainmenu\pmatic.dll")
  99. end
  100.